package spittr.model;

public class Spittle {
    private Integer id;
    private String message;
    private String authorName;

    public Spittle(Integer id, String message, String authorName) {
        this.id = id;
        this.message = message;
        this.authorName = authorName;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public String getAuthorName() {
        return authorName;
    }

    public void setAuthorName(String authorName) {
        this.authorName = authorName;
    }

    @Override
    public boolean equals(Object obj) {
        Spittle that = (Spittle)obj;
        return this.id == that.id && this.authorName.equals(that.authorName) && this.message.equals(that.message);
    }
}
